﻿using System;
using System.Collections.Generic;
using System.Diagnostics.CodeAnalysis;

using Fuse8.DomainFramework.Domain;

namespace Fuse8.DomainFramework.DataAccess.XmlDatabase
{
    /// <summary>
    /// 
    /// </summary>
    /// <typeparam name="T"></typeparam>
    [Serializable]
    public class XmlFileDBEntry<T> where T : class, IEntityObject
    {
        /// <summary>
        /// 
        /// </summary>
        [SuppressMessage("Microsoft.Design", "CA1002:DoNotExposeGenericLists",
            Justification = "Used for xml serialization.")]
        [SuppressMessage("Microsoft.Usage", "CA2227:CollectionPropertiesShouldBeReadOnly",
            Justification = "Getter and setter for serialization")]
        public List<T> Entries { get; set; }

        #region Constructor

        /// <summary>
        /// Need for serialization
        /// </summary>
        public XmlFileDBEntry()
        { }

        #endregion
    }
}
